cmake_minimum_required(VERSION 3.10)
option(NEED_TO_OPEN_CUDA "need to support cuda or not" OFF)

option(SUPPORT_DYNAMIC_LIBRARY "Support dynamic library or not" OFF)
set(OPTIMIZE_LEVEL "O0")

project(dyhhw_2)
# 设置Anaconda Python路径（替换为你的实际路径）
set(PYTHON_EXECUTABLE "/home/ubuntu/anaconda3/envs/hw/bin/python")
set(PYTHON_INCLUDE_DIRS "/home/ubuntu/anaconda3/envs/hw/include/python3.11")
set(PYTHON_LIBRARIES "/home/ubuntu/anaconda3/envs/hw/lib/libpython3.11.so")
set(NUMPY_INCLUDE_DIR "/home/ubuntu/anaconda3/envs/hw/lib/python3.11/site-packages/numpy/core/include")

set(DEVICE_NAME "ExampleFlow_KylinV10")

include(${CMAKE_SOURCE_DIR}/cmake/common.cmake)
include(${CMAKE_SOURCE_DIR}/cmake/algorithm.cmake)
include(${CMAKE_SOURCE_DIR}/cmake/preBuild.cmake)

include_directories(${ROOT_PATH}/headers ${PYTHON_INCLUDE_DIRS})
set(SRC_FILES main.cpp AppDelegate.h AppDelegate.cpp GlobalParameters.h)

add_subdirs()
get_all_targets(all_targets)
add_executable(${DEVICE_NAME} ${SRC_FILES})
target_link_libraries(${DEVICE_NAME} ${all_targets} ${MIDDLEWARE_LIB_NAME}  ${CMAKE_SOURCE_DIR}/Simu/libSimu.a ${CMAKE_SOURCE_DIR}/Spot/libSpot.a ${CMAKE_SOURCE_DIR}/Track/libTrack.a)
target_link_libraries(${DEVICE_NAME} ${all_targets} ${MIDDLEWARE_LIB_NAME} ${PYTHON_LIBRARIES} pthread)
target_include_directories(${DEVICE_NAME} PRIVATE ${PYTHON_INCLUDE_DIRS})

include(${CMAKE_SOURCE_DIR}/cmake/algorithmLib.cmake)
include(${CMAKE_SOURCE_DIR}/cmake/postBuild.cmake)
